package ssm.controller;

import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;
import ssm.mapper.UserMapper;
import ssm.pojo.User;

import javax.annotation.Resource;

/**
 * Created by sally on 2016/8/19.
 */
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(locations={"classpath:springmvc-servlet.xml"})
public class test {
    @Resource
    private UserMapper userMapper;

    @Test
    public void test() {
        User user = userMapper.getUserById(3);
        System.out.print(user);
    }
}
